package com.example.pojo;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import io.swagger.annotations.ApiOperation;
import lombok.Data;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

/**
* <p>
* 账号表
* </p>
*
* @author wsl
* @since 2022-03-27
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
@ApiModel(value = "Account对象", description = "账号表")
public class Acct implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("账户编号")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty("账号名")
    private String accountName;

    @ApiModelProperty("账户密码")
    private String accountPwd;

    @ApiModelProperty("图标")
    private String icon;

    @ApiModelProperty("性别")
    private String sex;

    @ApiModelProperty("账号邮箱")
    private String email;

    @ApiModelProperty("手机号码")
    private String phone;

    @ApiModelProperty("员工编号")
    private Integer empId;

    @ApiModelProperty("所属部门编号")
    private Integer departmentId;

    @ApiModelProperty("部门名称")
    @TableField(exist = false)
    private String departmentName;

    @ApiModelProperty("用户昵称")
    private String nickname;

    @ApiModelProperty("岗位编号")
    private Integer positionId;

    @ApiModelProperty("岗位名称")
    @TableField(exist = false)
    private String positionName;

    @ApiModelProperty("是否在线")
    private Integer online;

    @ApiModelProperty("备注")
    private String remark;

    @ApiModelProperty("是否启用(0未启用，1启用)")
    private Integer enabled;

    @ApiModelProperty("创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "Asia/Shanghai")
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createTime;

    @ApiModelProperty("修改时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "Asia/Shanghai")
    @TableField(fill = FieldFill.UPDATE)
    private LocalDateTime updateTime;

    @ApiModelProperty("角色")
    @TableField(exist = false)
    private List<Role> roleList;

    @ApiModelProperty("逻辑删除")
    private Integer deleted;
}
